package com.qf.sy2103.ssm.dao;

import com.qf.sy2103.ssm.entity.User;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface UserDao {

    User getUserById(@Param("id") Integer id);

//    User getUserByIdAndPassword(@Param("id") Integer id ,@Param("pwd")  String pwd);

    User getUserByIdAndPassword(Integer id, String pwd);


    List<User> getUserByInfo(User user);

    List<User> selectUsersByKeyword(@Param("keyword") String keyword);

    int deleteUserByid(@Param("id") Integer id);

    int updateUser(User user);

    int insertUser(User user);

    User getUserByName(@Param("name")  String name);

    List<User> getUsersByName(String name);

    List<User> getAllUsers();

    List<User> getAllUsersByCondition(User user);

    Integer getTotalCount();
}
